{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "import requests"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<bound method Response.json of <Response [200]>>"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "url = 'http://hqdata.jrj.com.cn/sgt/trade_history_sz_1year.js'\n",
    "r = requests.get(url)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [],
   "source": [
    "import re\n",
    "\n",
    "s = re.findall('var trahis_sz_1year=(.*?);',r.text,re.S)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "u'var trahis_sz_1year={\"summary\":{\"time\":\"2018-05-31 08:40:00\",\"total\":232}, \\r\\n\"Column\":{HqDate:0,Inflow:1,DailyBalance:2,DailyBalanceRatio:3,TotalBalance:4,NetBuyTurnover:5,BuyTurnover:6,SellTurnover:7,IndexVal:8,Pl:9},\\r\\n\"Data\":[\\r\\n[\"2018-05-30\",1708.91,50291.09,96.71,0.0,1648.29,5867.44,4219.15,10105.795,-2.35],[\"2018-05-29\",1268.03,50731.97,97.56,0.0,1229.65,5149.99,3920.34,10349.065,-1.11],[\"2018-05-28\",1740.37,50259.63,96.65,0.0,1653.06,5182.88,3529.82,10465.537,0.17],[\"2018-05-25\",670.51,51329.49,98.71,0.0,590.96,4394.71,3803.75,10448.225,-1.1],[\"2018-05-24\",1364.57,50635.43,97.38,0.0,1322.02,4551.27,3229.25,10564.127,-0.63],[\"2018-05-23\",1503.53,50496.47,97.11,0.0,1418.73,5568.09,4149.36,10631.124,-1.25],[\"2018-05-18\",1142.69,50857.31,97.8,0.0,1080.57,3806.96,2726.39,10672.522,0.35],[\"2018-05-17\",1035.65,50964.35,98.01,0.0,991.62,3778.65,2787.03,10635.499,-0.62],[\"2018-05-16\",966.16,51033.84,98.14,0.0,909.18,4692.32,3783.14,10701.323,-0.43],[\"2018-05-15\",2241.04,49758.96,95.69,0.0,2150.79,5283.05,3132.26,10747.993,0.72],[\"2018-05-14\",2364.31,49635.69,95.45,0.0,2286.8,5681.17,3394.37,10671.458,0.35],[\"2018-05-11\",484.21,51515.79,99.07,0.0,442.47,4025.43,3582.96,10634.3,-0.89],[\"2018-05-10\",1334.72,50665.28,97.43,0.0,1249.05,4284.35,3035.3,10729.766,0.38],[\"2018-05-09\",1449.13,50550.87,97.21,0.0,1397.31,3903.43,2506.12,10689.072,-0.17],[\"2018-05-08\",599.68,51400.32,98.85,0.0,528.8,4435.95,3907.15,10707.804,0.77],[\"2018-05-07\",1135.98,50864.02,97.82,0.0,1080.69,4703.24,3622.55,10626.509,1.92],[\"2018-05-04\",-787.07,52787.07,101.51,0.0,-849.69,3113.59,3963.28,10426.188,-0.31],[\"2018-05-02\",2338.11,49661.89,95.5,0.0,2248.73,6485.96,4237.23,10342.846,0.18],[\"2018-04-27\",-202.02,13202.02,101.55,0.0,-253.37,6274.58,6527.95,10324.468,0.31],[\"2018-04-26\",-3198.04,16198.04,124.6,0.0,-3231.45,4714.36,7945.81,10292.12,-2.42],[\"2018-04-25\",407.09,12592.91,96.87,0.0,351.01,3973.78,3622.77,10547.099,-0.09],[\"2018-04-24\",1570.99,11429.01,87.92,0.0,1525.23,5304.15,3778.92,10556.822,2.19],[\"2018-04-23\",977.02,12022.98,92.48,0.0,929.57,4889.2,3959.63,10330.629,-0.75],[\"2018-04-20\",-295.36,13295.36,102.27,0.0,-348.14,4041.88,4390.02,10408.91,-1.79],[\"2018-04-19\",1867.43,11132.57,85.64,0.0,1816.02,5526.81,3710.79,10598.353,1.02],[\"2018-04-18\",3301.66,9698.34,74.6,0.0,3238.81,7511.56,4272.75,10491.15,0.92],[\"2018-04-17\",-378.51,13378.51,102.91,0.0,-424.24,4720.19,5144.43,10395.157,-2.13],[\"2018-04-16\",1322.51,11677.49,89.83,0.0,1264.44,5080.06,3815.62,10621.788,-0.61],[\"2018-04-13\",1400.64,11599.36,89.23,0.0,1356.18,4116.38,2760.2,10687.018,-0.37],[\"2018-04-12\",1365.72,11634.28,89.49,0.0,1339.07,4063.63,2724.56,10726.955,-0.75],[\"2018-04-11\",842.49,12157.51,93.52,0.0,754.79,4856.24,4101.45,10808.37,0.4],[\"2018-04-10\",845.48,12154.52,93.5,0.0,802.33,4414.22,3611.89,10765.615,1.05],[\"2018-04-09\",985.49,12014.51,92.42,0.0,934.59,4186.66,3252.07,10653.376,-0.29],[\"2018-04-04\",665.91,12334.09,94.88,0.0,624.67,4294.88,3670.21,10684.562,-0.65],[\"2018-04-03\",560.58,12439.42,95.69,0.0,511.77,5546.6,5034.83,10754.286,-0.91],[\"2018-03-28\",-138.06,13138.06,101.06,0.0,-184.58,4652.3,4836.88,10630.689,-1.35],[\"2018-03-27\",-531.11,13531.11,104.09,0.0,-573.64,4775.64,5349.28,10775.71,2.0],[\"2018-03-26\",1894.02,11105.98,85.43,0.0,1816.83,5231.4,3414.57,10564.375,1.19],[\"2018-03-23\",-278.57,13278.57,102.14,0.0,-336.64,5379.94,5716.58,10439.986,-4.02],[\"2018-03-22\",305.38,12694.62,97.65,0.0,244.57,3715.13,3470.56,10877.252,-0.94],[\"2018-03-21\",780.52,12219.48,94.0,0.0,733.83,3945.9,3212.07,10980.549,-0.88],[\"2018-03-20\",-195.58,13195.58,101.5,0.0,-296.37,3292.68,3589.05,11077.801,0.08],[\"2018-03-19\",541.06,12458.94,95.84,0.0,463.58,3199.35,2735.77,11068.493,0.16],[\"2018-03-16\",-860.1,13860.1,106.62,0.0,-944.84,4147.46,5092.3,11051.122,-1.01],[\"2018-03-15\",539.18,12460.82,95.85,0.0,423.87,4020.29,3596.42,11163.654,0.22],[\"2018-03-14\",319.98,12680.02,97.54,0.0,252.64,3619.52,3366.88,11139.627,-0.91],[\"2018-03-13\",91.74,12908.26,99.29,0.0,58.3,3860.02,3801.72,11241.406,-0.75],[\"2018-03-12\",573.64,12426.36,95.59,0.0,504.17,4414.11,3909.94,11326.272,1.17],[\"2018-03-09\",444.33,12555.67,96.58,0.0,390.86,4093.65,3702.79,11194.914,1.6],[\"2018-03-08\",842.31,12157.69,93.52,0.0,788.46,3680.34,2891.88,11019.078,1.05],[\"2018-03-07\",-783.25,13783.25,106.02,0.0,-822.5,2951.53,3774.03,10904.988,-0.94],[\"2018-03-06\",419.69,12580.31,96.77,0.0,343.69,4198.03,3854.34,11007.952,1.22],[\"2018-03-05\",-54.99,13054.99,100.42,0.0,-102.06,3276.1,3378.16,10875.68,0.18],[\"2018-03-02\",-119.78,13119.78,100.92,0.0,-183.55,3758.13,3941.68,10856.246,-0.79],[\"2018-03-01\",831.55,12168.45,93.6,0.0,768.64,4195.93,3427.29,10943.131,1.06],[\"2018-02-28\",245.33,12754.67,98.11,0.0,205.21,4690.14,4484.93,10828.73,0.2],[\"2018-02-27\",993.33,12006.67,92.36,0.0,952.19,5093.66,4141.47,10807.535,-0.81],[\"2018-02-26\",1297.64,11702.36,90.02,0.0,1165.05,4233.93,3068.88,10895.562,2.18],[\"2018-02-23\",687.02,12312.98,94.72,0.0,593.54,3205.07,2611.53,10662.791,0.04],[\"2018-02-22\",1400.07,11599.93,89.23,0.0,1323.72,4585.64,3261.92,10658.937,2.18],[\"2018-02-14\",802.43,12197.57,93.83,0.0,761.17,2738.77,1977.6,10431.914,0.67],[\"2018-02-13\",-839.46,13839.46,106.46,0.0,-867.07,3119.3,3986.37,10362.432,0.69],[\"2018-02-12\",109.55,12890.45,99.16,0.0,46.42,4634.56,4588.14,10291.882,2.91],[\"2018-02-09\",-467.29,13467.29,103.59,0.0,-501.48,5387.95,5889.43,10001.227,-3.58],[\"2018-02-08\",1712.55,11287.45,86.83,0.0,1645.0,5969.16,4324.16,10372.588,1.23],[\"2018-02-07\",1961.18,11038.82,84.91,0.0,1927.64,7013.67,5086.03,10246.974,-1.26],[\"2018-02-06\",-2298.03,15298.03,117.68,0.0,-2360.32,4987.66,7347.98,10377.61,-4.23],[\"2018-02-05\",165.72,12834.28,98.73,0.0,89.4,4638.57,4549.17,10836.252,-0.81],[\"2018-02-02\",1174.73,11825.27,90.96,0.0,1101.97,5047.36,3945.39,10925.161,0.56],[\"2018-02-01\",1213.53,11786.47,90.67,0.0,1152.31,5445.7,4293.39,10864.342,-2.65],[\"2018-01-31\",356.18,12643.82,97.26,0.0,286.23,4285.83,3999.6,11159.676,-1.06],[\"2018-01-30\",701.3,12298.7,94.61,0.0,643.58,4348.74,3705.16,11278.781,-0.65],[\"2018-01-29\",-283.18,13283.18,102.18,0.0,-347.1,4483.21,4830.31,11352.716,-1.77],[\"2018-01-26\",1143.27,11856.73,91.21,0.0,1046.88,4078.35,3031.47,11557.816,0.05],[\"2018-01-25\",984.32,12015.68,92.43,0.0,919.6,4792.88,3873.28,11552.562,-0.47],[\"2018-01-24\",979.79,12020.21,92.46,0.0,820.04,4758.9,3938.86,11607.569,0.45],[\"2018-01-23\",348.6,12651.4,97.32,0.0,245.02,4583.49,4338.47,11555.255,0.37],[\"2018-01-22\",1237.07,11762.93,90.48,0.0,1121.34,4511.32,3389.98,11513.081,1.92],[\"2018-01-19\",844.28,12155.72,93.51,0.0,792.44,4025.66,3233.22,11296.273,-0.21],[\"2018-01-18\",633.75,12366.25,95.13,0.0,556.03,3924.87,3368.84,11319.905,0.14],[\"2018-01-17\",-350.91,13350.91,102.7,0.0,-423.15,4597.99,5021.14,11303.967,-0.73],[\"2018-01-16\",1587.98,11412.02,87.78,0.0,1489.76,4606.63,3116.87,11386.91,0.7],[\"2018-01-15\",8.73,12991.27,99.93,0.0,-53.28,3830.05,3883.33,11307.46,-1.35],[\"2018-01-12\",693.35,12306.65,94.67,0.0,615.0,3403.29,2788.29,11461.991,-0.02],[\"2018-01-11\",312.57,12687.43,97.6,0.0,232.56,3482.06,3249.5,11464.196,0.24],[\"2018-01-10\",319.56,12680.44,97.54,0.0,217.94,3638.48,3420.54,11437.084,-0.09],[\"2018-01-09\",1603.99,11396.01,87.66,0.0,1482.39,4124.02,2641.63,11447.091,0.57],[\"2018-01-08\",1180.74,11819.26,90.92,0.0,1077.36,4150.1,3072.74,11382.717,0.35],[\"2018-01-05\",1567.99,11432.01,87.94,0.0,1482.0,4144.62,2662.62,11342.848,0.01],[\"2018-01-04\",1702.95,11297.05,86.9,0.0,1618.65,4170.06,2551.41,11341.345,0.54],[\"2018-01-03\",1937.38,11062.62,85.1,0.0,1835.87,4652.43,2816.56,11280.296,0.91],[\"2018-01-02\",1399.9,11600.1,89.23,0.0,1355.62,3564.8,2209.18,11178.052,1.25],[\"2017-12-29\",769.88,12230.12,94.08,0.0,714.69,2691.98,1977.29,11040.45,0.61],[\"2017-12-28\",1464.13,11535.87,88.74,0.0,1347.0,3893.5,2546.5,10974.007,0.58],[\"2017-12-27\",130.12,12869.88,99.0,0.0,80.75,3281.38,3200.63,10911.212,-1.0],[\"2017-12-21\",623.96,12376.04,95.2,0.0,565.46,2831.64,2266.18,11118.247,1.04],[\"2017-12-20\",-281.83,13281.83,102.17,0.0,-347.92,2301.3,2649.22,11003.333,-0.65],[\"2017-12-19\",801.59,12198.41,93.83,0.0,735.77,2712.36,1976.59,11074.995,1.05],[\"2017-12-18\",442.26,12557.74,96.6,0.0,366.68,2511.65,2144.97,10960.116,-0.35],[\"2017-12-15\",-1458.53,14458.53,111.22,0.0,-1499.81,2378.88,3878.69,10998.117,-1.01],[\"2017-12-14\",461.28,12538.72,96.45,0.0,417.13,2998.99,2581.86,11110.178,-0.3],[\"2017-12-13\",857.43,12142.57,93.4,0.0,813.95,3012.4,2198.45,11143.889,0.91],[\"2017-12-12\",-172.95,13172.95,101.33,0.0,-209.21,2658.61,2867.82,11043.212,-0.9],[\"2017-12-11\",597.43,12402.57,95.4,0.0,528.26,3657.25,3128.99,11143.261,1.9],[\"2017-12-08\",1065.15,11934.85,91.81,0.0,882.1,3985.21,3103.11,10935.057,1.24],[\"2017-12-07\",-624.71,13624.71,104.81,0.0,-668.38,2986.72,3655.1,10801.253,-1.01],[\"2017-12-06\",-19.79,13019.79,100.15,0.0,-72.31,4017.53,4089.84,10911.329,0.52],[\"2017-12-05\",-417.15,13417.15,103.21,0.0,-483.71,3038.13,3521.84,10854.755,-1.45],[\"2017-12-04\",278.63,12721.37,97.86,0.0,221.48,3538.9,3317.42,11014.549,0.01],[\"2017-12-01\",2132.82,10867.18,83.59,0.0,2070.24,4270.66,2200.42,11013.154,0.63],[\"2017-11-30\",-467.95,13467.95,103.6,0.0,-726.85,2889.44,3616.29,10944.099,-1.25],[\"2017-11-29\",424.0,12576.0,96.74,0.0,358.96,3657.52,3298.56,11082.132,-0.08],[\"2017-11-28\",1370.18,11629.82,89.46,0.0,1281.55,3719.18,2437.63,11091.137,1.25],[\"2017-11-27\",-575.46,13575.46,104.43,0.0,-636.61,3415.22,4051.83,10954.181,-1.92],[\"2017-11-24\",41.66,12958.34,99.68,0.0,-41.91,4476.08,4517.99,11168.393,-0.06],[\"2017-11-23\",-75.43,13075.43,100.58,0.0,-125.33,4510.92,4636.25,11175.47,-3.33],[\"2017-11-22\",169.33,12830.67,98.7,0.0,87.85,3751.39,3663.54,11560.797,-0.36],[\"2017-11-21\",-102.55,13102.55,100.79,0.0,-185.11,4285.06,4470.17,11602.1,1.44],[\"2017-11-20\",774.65,12225.35,94.04,0.0,676.05,4690.93,4014.88,11437.546,1.28],[\"2017-11-17\",964.33,12035.67,92.58,0.0,894.81,4722.14,3827.33,11292.934,-2.12],[\"2017-11-16\",614.94,12385.06,95.27,0.0,491.34,3667.76,3176.42,11537.956,0.66],[\"2017-11-15\",-787.59,13787.59,106.06,0.0,-890.23,3595.02,4485.25,11462.11,-1.04],[\"2017-11-14\",443.92,12556.08,96.59,0.0,397.37,4101.96,3704.59,11582.925,-0.96],[\"2017-11-13\",540.07,12459.93,95.85,0.0,466.03,3995.22,3529.19,11694.996,0.43],[\"2017-11-10\",174.95,12825.05,98.65,0.0,117.84,3532.85,3415.01,11645.047,0.79],[\"2017-11-09\",1413.81,11586.19,89.12,0.0,1305.42,3998.96,2693.54,11553.24,0.92],[\"2017-11-08\",915.08,12084.92,92.96,0.0,841.45,4159.94,3318.49,11447.401,-0.18],[\"2017-11-07\",666.76,12333.24,94.87,0.0,614.32,4062.33,3448.01,11467.969,0.83],[\"2017-11-06\",655.57,12344.43,94.96,0.0,593.05,3899.37,3306.32,11373.736,1.41],[\"2017-11-03\",533.76,12466.24,95.89,0.0,446.81,3282.11,2835.3,11215.194,-0.68],[\"2017-11-02\",779.18,12220.82,94.01,0.0,707.21,2999.0,2291.79,11292.422,-0.51],[\"2017-11-01\",1053.04,11946.96,91.9,0.0,1002.05,3571.01,2568.96,11350.321,-0.15],[\"2017-10-31\",690.81,12309.19,94.69,0.0,632.29,3634.88,3002.59,11367.619,0.49],[\"2017-10-30\",239.83,12760.17,98.16,0.0,173.38,3504.45,3331.07,11312.607,-1.15],[\"2017-10-27\",215.39,12784.61,98.34,0.0,167.06,3057.27,2890.21,11444.524,-0.15],[\"2017-10-26\",241.66,12758.34,98.14,0.0,182.2,3765.41,3583.21,11461.285,0.21],[\"2017-10-25\",328.13,12671.87,97.48,0.0,257.29,2783.81,2526.52,11437.209,0.86],[\"2017-10-24\",-943.46,13943.46,107.26,0.0,-1012.92,2539.9,3552.82,11339.127,0.29],[\"2017-10-23\",-190.19,13190.19,101.46,0.0,-248.59,2544.9,2793.49,11306.307,0.6],[\"2017-10-20\",90.91,12909.09,99.3,0.0,30.77,2764.75,2733.98,11238.877,0.44],[\"2017-10-19\",167.7,12832.3,98.71,0.0,114.12,3032.19,2918.07,11189.553,-0.83],[\"2017-10-18\",223.47,12776.53,98.28,0.0,157.65,2585.82,2428.17,11282.747,0.07],[\"2017-10-17\",1592.31,11407.69,87.75,0.0,1528.46,3794.13,2265.67,11275.341,0.04],[\"2017-10-16\",1208.51,11791.49,90.7,0.0,1099.43,3733.65,2634.22,11271.199,-1.12],[\"2017-10-13\",1084.13,11915.87,91.66,0.0,985.75,2888.8,1903.05,11399.094,0.81],[\"2017-10-12\",893.54,12106.46,93.13,0.0,822.77,2698.49,1875.72,11307.325,-0.05],[\"2017-10-11\",1147.25,11852.75,91.17,0.0,1057.26,4158.56,3101.3,11312.496,-0.15],[\"2017-10-10\",1754.27,11245.73,86.51,0.0,1693.44,3839.09,2145.65,11329.513,0.58],[\"2017-10-09\",2968.41,10031.59,77.17,0.0,2888.99,5159.83,2270.84,11264.273,1.6],[\"2017-09-29\",778.02,12221.98,94.02,0.0,732.21,2482.95,1750.74,11087.187,0.51],[\"2017-09-28\",-138.14,13138.14,101.06,0.0,-180.98,1797.79,1978.77,11031.421,-0.05],[\"2017-09-27\",876.26,12123.74,93.26,0.0,843.99,2425.46,1581.47,11036.78,0.79],[\"2017-09-26\",211.66,12788.34,98.37,0.0,168.5,2348.68,2180.18,10950.769,0.18],[\"2017-09-25\",157.41,12842.59,98.79,0.0,111.87,2579.91,2468.04,10930.67,-1.26],[\"2017-09-22\",1050.18,11949.82,91.92,0.0,969.4,2900.77,1931.37,11069.822,-0.26],[\"2017-09-21\",405.5,12594.5,96.88,0.0,372.22,2831.07,2458.85,11098.339,-0.83],[\"2017-09-20\",1157.62,11842.38,91.1,0.0,1095.32,3076.15,1980.83,11191.13,0.97],[\"2017-09-19\",330.59,12669.41,97.46,0.0,292.05,2833.24,2541.19,11083.899,-0.62],[\"2017-09-18\",1905.98,11094.02,85.34,0.0,1862.39,3602.84,1740.45,11153.532,0.82],[\"2017-09-15\",-99.38,13099.38,100.76,0.0,-303.41,2807.93,3111.34,11063.104,-0.07],[\"2017-09-14\",387.5,12612.5,97.02,0.0,341.51,2316.0,1974.49,11070.492,-0.19],[\"2017-09-13\",634.62,12365.38,95.12,0.0,575.33,2445.49,1870.16,11091.493,0.43],[\"2017-09-11\",309.94,12690.06,97.62,0.0,258.02,2388.46,2130.44,11053.729,0.76],[\"2017-09-08\",822.38,12177.62,93.67,0.0,734.06,2800.19,2066.13,10970.773,0.01],[\"2017-09-07\",809.51,12190.49,93.77,0.0,762.43,2808.82,2046.39,10969.127,-0.5],[\"2017-09-06\",209.43,12790.57,98.39,0.0,130.03,2111.89,1981.86,11024.586,0.34],[\"2017-09-05\",895.93,12104.07,93.11,0.0,831.72,2472.62,1640.9,10986.948,0.22],[\"2017-09-04\",1317.01,11682.99,89.87,0.0,1217.76,3180.59,1962.83,10962.854,0.76],[\"2017-09-01\",2055.2,10944.8,84.19,0.0,2016.81,3712.71,1695.9,10880.557,0.59],[\"2017-08-31\",784.27,12215.73,93.97,0.0,642.37,2768.02,2125.65,10816.644,0.03],[\"2017-08-30\",1136.84,11863.16,91.26,0.0,1052.23,2614.15,1561.92,10813.927,0.48],[\"2017-08-29\",921.23,12078.77,92.91,0.0,871.87,2510.39,1638.52,10762.366,-0.44],[\"2017-08-28\",1959.42,11040.58,84.93,0.0,1921.23,3748.43,1827.2,10809.736,1.41],[\"2017-08-25\",1452.0,11548.0,88.83,0.0,1395.31,3239.05,1843.74,10659.009,1.0],[\"2017-08-24\",590.73,12409.27,95.46,0.0,529.4,2394.38,1864.98,10552.962,-0.63],[\"2017-08-22\",304.58,12695.42,97.66,0.0,264.11,2214.17,1950.06,0.0,0.0],[\"2017-08-21\",435.21,12564.79,96.65,0.0,341.18,2149.21,1808.03,10689.773,0.71],[\"2017-08-18\",-1011.18,14011.18,107.78,0.0,-1060.53,1924.42,2984.95,10614.083,-0.37],[\"2017-08-17\",814.64,12185.36,93.73,0.0,706.97,2291.43,1584.46,10653.73,0.5],[\"2017-08-16\",715.18,12284.82,94.5,0.0,663.75,2381.5,1717.75,10600.779,0.39],[\"2017-08-15\",221.06,12778.94,98.3,0.0,187.27,1911.15,1723.88,10559.778,0.38],[\"2017-08-14\",537.85,12462.15,95.86,0.0,487.5,2198.51,1711.01,10519.804,2.22],[\"2017-08-11\",-91.15,13091.15,100.7,0.0,-126.57,1987.69,2114.26,10291.347,-1.81],[\"2017-08-10\",247.88,12752.12,98.09,0.0,212.11,1989.84,1777.73,10480.641,-0.61],[\"2017-08-09\",570.53,12429.47,95.61,0.0,515.29,1859.29,1344.0,10544.589,0.46],[\"2017-08-08\",864.55,12135.45,93.35,0.0,809.13,2063.98,1254.85,10496.246,0.43],[\"2017-08-07\",1323.62,11676.38,89.82,0.0,1236.35,2440.16,1203.81,10451.083,0.87],[\"2017-08-04\",868.53,12131.47,93.32,0.0,798.0,2221.35,1423.35,10361.231,-0.72],[\"2017-08-03\",1184.02,11815.98,90.89,0.0,1065.1,2534.98,1469.88,10436.172,-0.32],[\"2017-08-01\",635.1,12364.9,95.11,0.0,591.6,1861.07,1269.47,10525.346,0.19],[\"2017-07-31\",1063.16,11936.84,91.82,0.0,1000.68,2226.3,1225.62,10505.044,0.64],[\"2017-07-28\",940.43,12059.57,92.77,0.0,895.6,2238.69,1343.09,10437.938,0.41],[\"2017-07-26\",589.45,12410.55,95.47,0.0,546.98,2386.0,1839.02,10297.343,-0.54],[\"2017-07-25\",1289.14,11710.86,90.08,0.0,1255.91,2534.75,1278.84,10353.211,-0.49],[\"2017-07-21\",1218.5,11781.5,90.63,0.0,1192.78,2174.4,981.62,10364.82,-0.02],[\"2017-07-20\",396.56,12603.44,96.95,0.0,357.94,1848.37,1490.43,10366.983,0.69],[\"2017-07-19\",1107.74,11892.26,91.48,0.0,1049.84,2486.77,1436.93,10295.575,1.9],[\"2017-07-18\",969.04,12030.96,92.55,0.0,917.2,2566.0,1648.8,10103.763,0.48],[\"2017-07-17\",1371.96,11628.04,89.45,0.0,1330.94,2928.17,1597.23,10055.796,-3.57],[\"2017-07-14\",267.33,12732.67,97.94,0.0,196.2,1481.94,1285.74,10427.787,-0.37],[\"2017-07-13\",651.52,12348.48,94.99,0.0,599.63,2001.54,1401.91,10466.103,0.12],[\"2017-07-12\",1079.17,11920.83,91.7,0.0,953.42,2340.87,1387.45,10453.193,-0.14],[\"2017-07-11\",753.74,12246.26,94.2,0.0,702.29,2007.49,1305.2,10467.711,-0.36],[\"2017-07-10\",894.62,12105.38,93.12,0.0,819.65,2105.93,1286.28,10505.601,-0.55],[\"2017-07-07\",481.96,12518.04,96.29,0.0,443.89,1595.59,1151.7,10563.717,0.02],[\"2017-07-06\",-196.51,13196.51,101.51,0.0,-228.07,1564.29,1792.36,10562.055,0.01],[\"2017-07-05\",339.22,12660.78,97.39,0.0,281.07,1517.62,1236.55,10561.089,0.82],[\"2017-07-04\",-201.72,13201.72,101.55,0.0,-239.38,1572.81,1812.19,10474.828,-0.57],[\"2017-07-03\",321.76,12678.24,97.52,0.0,264.57,1474.73,1210.16,10535.046,0.05],[\"2017-06-30\",-112.32,13112.32,100.86,0.0,-150.95,1396.31,1547.26,10529.609,0.17],[\"2017-06-29\",1021.08,11978.92,92.15,0.0,923.7,2362.6,1438.9,10511.86,0.58],[\"2017-06-28\",401.52,12598.48,96.91,0.0,352.53,2677.21,2324.68,10451.565,-0.8],[\"2017-06-27\",750.26,12249.74,94.23,0.0,702.66,2254.52,1551.86,10535.364,-0.02],[\"2017-06-26\",475.64,12524.36,96.34,0.0,441.41,2182.41,1741.0,10537.591,1.65],[\"2017-06-23\",1061.9,11938.1,91.83,0.0,928.0,2502.22,1574.22,10366.777,0.99],[\"2017-06-22\",1279.85,11720.15,90.15,0.0,1242.75,3014.58,1771.83,10265.2,-0.98],[\"2017-06-21\",1050.47,11949.53,91.92,0.0,984.98,2256.29,1271.31,10367.173,0.76],[\"2017-06-20\",494.46,12505.54,96.2,0.0,453.37,1765.51,1312.14,10288.527,0.25],[\"2017-06-19\",1194.85,11805.15,90.81,0.0,1151.21,2338.43,1187.22,10262.8,0.7],[\"2017-06-16\",488.89,12511.11,96.24,0.0,444.57,2407.59,1963.02,10191.24,-0.3],[\"2017-06-15\",869.3,12130.7,93.31,0.0,837.4,2331.77,1494.37,10221.692,0.69],[\"2017-06-14\",-258.04,13258.04,101.98,0.0,-287.79,1608.76,1896.55,10151.534,-0.72],[\"2017-06-13\",697.3,12302.7,94.64,0.0,647.62,2225.87,1578.25,10224.818,1.04],[\"2017-06-12\",97.72,12902.28,99.25,0.0,21.12,2121.16,2100.04,10119.987,-0.56],[\"2017-06-09\",564.23,12435.77,95.66,0.0,503.35,2489.18,1985.83,10177.447,0.28],[\"2017-06-08\",1390.35,11609.65,89.31,0.0,1326.63,2631.47,1304.84,10148.722,0.38],[\"2017-06-07\",1807.93,11192.07,86.09,0.0,1742.92,3208.27,1465.35,10109.876,1.96],[\"2017-06-06\",1232.6,11767.4,90.52,0.0,1186.83,2198.93,1012.1,9915.923,0.74],[\"2017-06-05\",1016.79,11983.21,92.18,0.0,992.85,2043.07,1050.22,9842.602,0.49],[\"2017-06-02\",1026.1,11973.9,92.11,0.0,965.89,2022.76,1056.87,9794.889,0.66],[\"2017-06-01\",266.02,12733.98,97.95,0.0,238.61,1904.18,1665.57,9730.326,-1.36],[\"2017-05-31\",-213.71,13213.71,101.64,0.0,-241.58,1666.11,1907.69,9864.845,0.06]]}; '"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.text"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<type 'list'>\n"
     ]
    }
   ],
   "source": [
    "print(type(s)\n",)
    "# ret = eval(s)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "ename": "NameError",
     "evalue": "name 'HqDate' is not defined",
     "output_type": "error",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mNameError\u001b[0m                                 Traceback (most recent call last)",
      "\u001b[1;32m<ipython-input-16-cc2031c6e752>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m()\u001b[0m\n\u001b[0;32m      1\u001b[0m \u001b[0mret\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0ms\u001b[0m\u001b[1;33m[\u001b[0m\u001b[1;36m0\u001b[0m\u001b[1;33m]\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m----> 2\u001b[1;33m \u001b[0mresult\u001b[0m \u001b[1;33m=\u001b[0m\u001b[0meval\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mret\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[1;32m<string>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m()\u001b[0m\n",
      "\u001b[1;31mNameError\u001b[0m: name 'HqDate' is not defined"
     ]
    }
   ],
   "source": [
    "ret = s[0]\n",
    "result =eval(ret)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "metadata": {},
   "outputs": [
    {
     "ename": "ValueError",
     "evalue": "Expecting property name enclosed in double quotes: line 2 column 11 (char 67)",
     "output_type": "error",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mValueError\u001b[0m                                Traceback (most recent call last)",
      "\u001b[1;32m<ipython-input-24-3e15b0e18bb0>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m()\u001b[0m\n\u001b[0;32m      1\u001b[0m \u001b[1;32mimport\u001b[0m \u001b[0mjson\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m----> 2\u001b[1;33m \u001b[0mjs\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mjson\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mloads\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mret\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[1;32mc:\\python27\\lib\\json\\__init__.pyc\u001b[0m in \u001b[0;36mloads\u001b[1;34m(s, encoding, cls, object_hook, parse_float, parse_int, parse_constant, object_pairs_hook, **kw)\u001b[0m\n\u001b[0;32m    337\u001b[0m             \u001b[0mparse_int\u001b[0m \u001b[1;32mis\u001b[0m \u001b[0mNone\u001b[0m \u001b[1;32mand\u001b[0m \u001b[0mparse_float\u001b[0m \u001b[1;32mis\u001b[0m \u001b[0mNone\u001b[0m \u001b[1;32mand\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    338\u001b[0m             parse_constant is None and object_pairs_hook is None and not kw):\n\u001b[1;32m--> 339\u001b[1;33m         \u001b[1;32mreturn\u001b[0m \u001b[0m_default_decoder\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mdecode\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    340\u001b[0m     \u001b[1;32mif\u001b[0m \u001b[0mcls\u001b[0m \u001b[1;32mis\u001b[0m \u001b[0mNone\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    341\u001b[0m         \u001b[0mcls\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mJSONDecoder\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mc:\\python27\\lib\\json\\decoder.pyc\u001b[0m in \u001b[0;36mdecode\u001b[1;34m(self, s, _w)\u001b[0m\n\u001b[0;32m    362\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    363\u001b[0m         \"\"\"\n\u001b[1;32m--> 364\u001b[1;33m         \u001b[0mobj\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mend\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mraw_decode\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0midx\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0m_w\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m0\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    365\u001b[0m         \u001b[0mend\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0m_w\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mend\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    366\u001b[0m         \u001b[1;32mif\u001b[0m \u001b[0mend\u001b[0m \u001b[1;33m!=\u001b[0m \u001b[0mlen\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;32mc:\\python27\\lib\\json\\decoder.pyc\u001b[0m in \u001b[0;36mraw_decode\u001b[1;34m(self, s, idx)\u001b[0m\n\u001b[0;32m    378\u001b[0m         \"\"\"\n\u001b[0;32m    379\u001b[0m         \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 380\u001b[1;33m             \u001b[0mobj\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mend\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mscan_once\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0ms\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0midx\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m    381\u001b[0m         \u001b[1;32mexcept\u001b[0m \u001b[0mStopIteration\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m    382\u001b[0m             \u001b[1;32mraise\u001b[0m \u001b[0mValueError\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m\"No JSON object could be decoded\"\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;31mValueError\u001b[0m: Expecting property name enclosed in double quotes: line 2 column 11 (char 67)"
     ]
    }
   ],
   "source": [
    "import json\n",
    "js = json.loads(ret)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "ename": "AttributeError",
     "evalue": "'str' object has no attribute 'get'",
     "output_type": "error",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mAttributeError\u001b[0m                            Traceback (most recent call last)",
      "\u001b[1;32m<ipython-input-23-5563ec523afc>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m()\u001b[0m\n\u001b[1;32m----> 1\u001b[1;33m \u001b[0mjs\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mget\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'sumary'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[1;31mAttributeError\u001b[0m: 'str' object has no attribute 'get'"
     ]
    }
   ],
   "source": [
    "js.get('sumary')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "unicode"
      ]
     },
     "execution_count": 26,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "type(ret)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "u'{\"summary\":{\"time\":\"2018-05-31 08:40:00\",\"total\":232}, \\r\\n\"Column\":{HqDate:0,Inflow:1,DailyBalance:2,DailyBalanceRatio:3,TotalBalance:4,NetBuyTurnover:5,BuyTurnover:6,SellTurnover:7,IndexVal:8,Pl:9},\\r\\n\"Data\":[\\r\\n[\"2018-05-30\",1708.91,50291.09,96.71,0.0,1648.29,5867.44,4219.15,10105.795,-2.35],[\"2018-05-29\",1268.03,50731.97,97.56,0.0,1229.65,5149.99,3920.34,10349.065,-1.11],[\"2018-05-28\",1740.37,50259.63,96.65,0.0,1653.06,5182.88,3529.82,10465.537,0.17],[\"2018-05-25\",670.51,51329.49,98.71,0.0,590.96,4394.71,3803.75,10448.225,-1.1],[\"2018-05-24\",1364.57,50635.43,97.38,0.0,1322.02,4551.27,3229.25,10564.127,-0.63],[\"2018-05-23\",1503.53,50496.47,97.11,0.0,1418.73,5568.09,4149.36,10631.124,-1.25],[\"2018-05-18\",1142.69,50857.31,97.8,0.0,1080.57,3806.96,2726.39,10672.522,0.35],[\"2018-05-17\",1035.65,50964.35,98.01,0.0,991.62,3778.65,2787.03,10635.499,-0.62],[\"2018-05-16\",966.16,51033.84,98.14,0.0,909.18,4692.32,3783.14,10701.323,-0.43],[\"2018-05-15\",2241.04,49758.96,95.69,0.0,2150.79,5283.05,3132.26,10747.993,0.72],[\"2018-05-14\",2364.31,49635.69,95.45,0.0,2286.8,5681.17,3394.37,10671.458,0.35],[\"2018-05-11\",484.21,51515.79,99.07,0.0,442.47,4025.43,3582.96,10634.3,-0.89],[\"2018-05-10\",1334.72,50665.28,97.43,0.0,1249.05,4284.35,3035.3,10729.766,0.38],[\"2018-05-09\",1449.13,50550.87,97.21,0.0,1397.31,3903.43,2506.12,10689.072,-0.17],[\"2018-05-08\",599.68,51400.32,98.85,0.0,528.8,4435.95,3907.15,10707.804,0.77],[\"2018-05-07\",1135.98,50864.02,97.82,0.0,1080.69,4703.24,3622.55,10626.509,1.92],[\"2018-05-04\",-787.07,52787.07,101.51,0.0,-849.69,3113.59,3963.28,10426.188,-0.31],[\"2018-05-02\",2338.11,49661.89,95.5,0.0,2248.73,6485.96,4237.23,10342.846,0.18],[\"2018-04-27\",-202.02,13202.02,101.55,0.0,-253.37,6274.58,6527.95,10324.468,0.31],[\"2018-04-26\",-3198.04,16198.04,124.6,0.0,-3231.45,4714.36,7945.81,10292.12,-2.42],[\"2018-04-25\",407.09,12592.91,96.87,0.0,351.01,3973.78,3622.77,10547.099,-0.09],[\"2018-04-24\",1570.99,11429.01,87.92,0.0,1525.23,5304.15,3778.92,10556.822,2.19],[\"2018-04-23\",977.02,12022.98,92.48,0.0,929.57,4889.2,3959.63,10330.629,-0.75],[\"2018-04-20\",-295.36,13295.36,102.27,0.0,-348.14,4041.88,4390.02,10408.91,-1.79],[\"2018-04-19\",1867.43,11132.57,85.64,0.0,1816.02,5526.81,3710.79,10598.353,1.02],[\"2018-04-18\",3301.66,9698.34,74.6,0.0,3238.81,7511.56,4272.75,10491.15,0.92],[\"2018-04-17\",-378.51,13378.51,102.91,0.0,-424.24,4720.19,5144.43,10395.157,-2.13],[\"2018-04-16\",1322.51,11677.49,89.83,0.0,1264.44,5080.06,3815.62,10621.788,-0.61],[\"2018-04-13\",1400.64,11599.36,89.23,0.0,1356.18,4116.38,2760.2,10687.018,-0.37],[\"2018-04-12\",1365.72,11634.28,89.49,0.0,1339.07,4063.63,2724.56,10726.955,-0.75],[\"2018-04-11\",842.49,12157.51,93.52,0.0,754.79,4856.24,4101.45,10808.37,0.4],[\"2018-04-10\",845.48,12154.52,93.5,0.0,802.33,4414.22,3611.89,10765.615,1.05],[\"2018-04-09\",985.49,12014.51,92.42,0.0,934.59,4186.66,3252.07,10653.376,-0.29],[\"2018-04-04\",665.91,12334.09,94.88,0.0,624.67,4294.88,3670.21,10684.562,-0.65],[\"2018-04-03\",560.58,12439.42,95.69,0.0,511.77,5546.6,5034.83,10754.286,-0.91],[\"2018-03-28\",-138.06,13138.06,101.06,0.0,-184.58,4652.3,4836.88,10630.689,-1.35],[\"2018-03-27\",-531.11,13531.11,104.09,0.0,-573.64,4775.64,5349.28,10775.71,2.0],[\"2018-03-26\",1894.02,11105.98,85.43,0.0,1816.83,5231.4,3414.57,10564.375,1.19],[\"2018-03-23\",-278.57,13278.57,102.14,0.0,-336.64,5379.94,5716.58,10439.986,-4.02],[\"2018-03-22\",305.38,12694.62,97.65,0.0,244.57,3715.13,3470.56,10877.252,-0.94],[\"2018-03-21\",780.52,12219.48,94.0,0.0,733.83,3945.9,3212.07,10980.549,-0.88],[\"2018-03-20\",-195.58,13195.58,101.5,0.0,-296.37,3292.68,3589.05,11077.801,0.08],[\"2018-03-19\",541.06,12458.94,95.84,0.0,463.58,3199.35,2735.77,11068.493,0.16],[\"2018-03-16\",-860.1,13860.1,106.62,0.0,-944.84,4147.46,5092.3,11051.122,-1.01],[\"2018-03-15\",539.18,12460.82,95.85,0.0,423.87,4020.29,3596.42,11163.654,0.22],[\"2018-03-14\",319.98,12680.02,97.54,0.0,252.64,3619.52,3366.88,11139.627,-0.91],[\"2018-03-13\",91.74,12908.26,99.29,0.0,58.3,3860.02,3801.72,11241.406,-0.75],[\"2018-03-12\",573.64,12426.36,95.59,0.0,504.17,4414.11,3909.94,11326.272,1.17],[\"2018-03-09\",444.33,12555.67,96.58,0.0,390.86,4093.65,3702.79,11194.914,1.6],[\"2018-03-08\",842.31,12157.69,93.52,0.0,788.46,3680.34,2891.88,11019.078,1.05],[\"2018-03-07\",-783.25,13783.25,106.02,0.0,-822.5,2951.53,3774.03,10904.988,-0.94],[\"2018-03-06\",419.69,12580.31,96.77,0.0,343.69,4198.03,3854.34,11007.952,1.22],[\"2018-03-05\",-54.99,13054.99,100.42,0.0,-102.06,3276.1,3378.16,10875.68,0.18],[\"2018-03-02\",-119.78,13119.78,100.92,0.0,-183.55,3758.13,3941.68,10856.246,-0.79],[\"2018-03-01\",831.55,12168.45,93.6,0.0,768.64,4195.93,3427.29,10943.131,1.06],[\"2018-02-28\",245.33,12754.67,98.11,0.0,205.21,4690.14,4484.93,10828.73,0.2],[\"2018-02-27\",993.33,12006.67,92.36,0.0,952.19,5093.66,4141.47,10807.535,-0.81],[\"2018-02-26\",1297.64,11702.36,90.02,0.0,1165.05,4233.93,3068.88,10895.562,2.18],[\"2018-02-23\",687.02,12312.98,94.72,0.0,593.54,3205.07,2611.53,10662.791,0.04],[\"2018-02-22\",1400.07,11599.93,89.23,0.0,1323.72,4585.64,3261.92,10658.937,2.18],[\"2018-02-14\",802.43,12197.57,93.83,0.0,761.17,2738.77,1977.6,10431.914,0.67],[\"2018-02-13\",-839.46,13839.46,106.46,0.0,-867.07,3119.3,3986.37,10362.432,0.69],[\"2018-02-12\",109.55,12890.45,99.16,0.0,46.42,4634.56,4588.14,10291.882,2.91],[\"2018-02-09\",-467.29,13467.29,103.59,0.0,-501.48,5387.95,5889.43,10001.227,-3.58],[\"2018-02-08\",1712.55,11287.45,86.83,0.0,1645.0,5969.16,4324.16,10372.588,1.23],[\"2018-02-07\",1961.18,11038.82,84.91,0.0,1927.64,7013.67,5086.03,10246.974,-1.26],[\"2018-02-06\",-2298.03,15298.03,117.68,0.0,-2360.32,4987.66,7347.98,10377.61,-4.23],[\"2018-02-05\",165.72,12834.28,98.73,0.0,89.4,4638.57,4549.17,10836.252,-0.81],[\"2018-02-02\",1174.73,11825.27,90.96,0.0,1101.97,5047.36,3945.39,10925.161,0.56],[\"2018-02-01\",1213.53,11786.47,90.67,0.0,1152.31,5445.7,4293.39,10864.342,-2.65],[\"2018-01-31\",356.18,12643.82,97.26,0.0,286.23,4285.83,3999.6,11159.676,-1.06],[\"2018-01-30\",701.3,12298.7,94.61,0.0,643.58,4348.74,3705.16,11278.781,-0.65],[\"2018-01-29\",-283.18,13283.18,102.18,0.0,-347.1,4483.21,4830.31,11352.716,-1.77],[\"2018-01-26\",1143.27,11856.73,91.21,0.0,1046.88,4078.35,3031.47,11557.816,0.05],[\"2018-01-25\",984.32,12015.68,92.43,0.0,919.6,4792.88,3873.28,11552.562,-0.47],[\"2018-01-24\",979.79,12020.21,92.46,0.0,820.04,4758.9,3938.86,11607.569,0.45],[\"2018-01-23\",348.6,12651.4,97.32,0.0,245.02,4583.49,4338.47,11555.255,0.37],[\"2018-01-22\",1237.07,11762.93,90.48,0.0,1121.34,4511.32,3389.98,11513.081,1.92],[\"2018-01-19\",844.28,12155.72,93.51,0.0,792.44,4025.66,3233.22,11296.273,-0.21],[\"2018-01-18\",633.75,12366.25,95.13,0.0,556.03,3924.87,3368.84,11319.905,0.14],[\"2018-01-17\",-350.91,13350.91,102.7,0.0,-423.15,4597.99,5021.14,11303.967,-0.73],[\"2018-01-16\",1587.98,11412.02,87.78,0.0,1489.76,4606.63,3116.87,11386.91,0.7],[\"2018-01-15\",8.73,12991.27,99.93,0.0,-53.28,3830.05,3883.33,11307.46,-1.35],[\"2018-01-12\",693.35,12306.65,94.67,0.0,615.0,3403.29,2788.29,11461.991,-0.02],[\"2018-01-11\",312.57,12687.43,97.6,0.0,232.56,3482.06,3249.5,11464.196,0.24],[\"2018-01-10\",319.56,12680.44,97.54,0.0,217.94,3638.48,3420.54,11437.084,-0.09],[\"2018-01-09\",1603.99,11396.01,87.66,0.0,1482.39,4124.02,2641.63,11447.091,0.57],[\"2018-01-08\",1180.74,11819.26,90.92,0.0,1077.36,4150.1,3072.74,11382.717,0.35],[\"2018-01-05\",1567.99,11432.01,87.94,0.0,1482.0,4144.62,2662.62,11342.848,0.01],[\"2018-01-04\",1702.95,11297.05,86.9,0.0,1618.65,4170.06,2551.41,11341.345,0.54],[\"2018-01-03\",1937.38,11062.62,85.1,0.0,1835.87,4652.43,2816.56,11280.296,0.91],[\"2018-01-02\",1399.9,11600.1,89.23,0.0,1355.62,3564.8,2209.18,11178.052,1.25],[\"2017-12-29\",769.88,12230.12,94.08,0.0,714.69,2691.98,1977.29,11040.45,0.61],[\"2017-12-28\",1464.13,11535.87,88.74,0.0,1347.0,3893.5,2546.5,10974.007,0.58],[\"2017-12-27\",130.12,12869.88,99.0,0.0,80.75,3281.38,3200.63,10911.212,-1.0],[\"2017-12-21\",623.96,12376.04,95.2,0.0,565.46,2831.64,2266.18,11118.247,1.04],[\"2017-12-20\",-281.83,13281.83,102.17,0.0,-347.92,2301.3,2649.22,11003.333,-0.65],[\"2017-12-19\",801.59,12198.41,93.83,0.0,735.77,2712.36,1976.59,11074.995,1.05],[\"2017-12-18\",442.26,12557.74,96.6,0.0,366.68,2511.65,2144.97,10960.116,-0.35],[\"2017-12-15\",-1458.53,14458.53,111.22,0.0,-1499.81,2378.88,3878.69,10998.117,-1.01],[\"2017-12-14\",461.28,12538.72,96.45,0.0,417.13,2998.99,2581.86,11110.178,-0.3],[\"2017-12-13\",857.43,12142.57,93.4,0.0,813.95,3012.4,2198.45,11143.889,0.91],[\"2017-12-12\",-172.95,13172.95,101.33,0.0,-209.21,2658.61,2867.82,11043.212,-0.9],[\"2017-12-11\",597.43,12402.57,95.4,0.0,528.26,3657.25,3128.99,11143.261,1.9],[\"2017-12-08\",1065.15,11934.85,91.81,0.0,882.1,3985.21,3103.11,10935.057,1.24],[\"2017-12-07\",-624.71,13624.71,104.81,0.0,-668.38,2986.72,3655.1,10801.253,-1.01],[\"2017-12-06\",-19.79,13019.79,100.15,0.0,-72.31,4017.53,4089.84,10911.329,0.52],[\"2017-12-05\",-417.15,13417.15,103.21,0.0,-483.71,3038.13,3521.84,10854.755,-1.45],[\"2017-12-04\",278.63,12721.37,97.86,0.0,221.48,3538.9,3317.42,11014.549,0.01],[\"2017-12-01\",2132.82,10867.18,83.59,0.0,2070.24,4270.66,2200.42,11013.154,0.63],[\"2017-11-30\",-467.95,13467.95,103.6,0.0,-726.85,2889.44,3616.29,10944.099,-1.25],[\"2017-11-29\",424.0,12576.0,96.74,0.0,358.96,3657.52,3298.56,11082.132,-0.08],[\"2017-11-28\",1370.18,11629.82,89.46,0.0,1281.55,3719.18,2437.63,11091.137,1.25],[\"2017-11-27\",-575.46,13575.46,104.43,0.0,-636.61,3415.22,4051.83,10954.181,-1.92],[\"2017-11-24\",41.66,12958.34,99.68,0.0,-41.91,4476.08,4517.99,11168.393,-0.06],[\"2017-11-23\",-75.43,13075.43,100.58,0.0,-125.33,4510.92,4636.25,11175.47,-3.33],[\"2017-11-22\",169.33,12830.67,98.7,0.0,87.85,3751.39,3663.54,11560.797,-0.36],[\"2017-11-21\",-102.55,13102.55,100.79,0.0,-185.11,4285.06,4470.17,11602.1,1.44],[\"2017-11-20\",774.65,12225.35,94.04,0.0,676.05,4690.93,4014.88,11437.546,1.28],[\"2017-11-17\",964.33,12035.67,92.58,0.0,894.81,4722.14,3827.33,11292.934,-2.12],[\"2017-11-16\",614.94,12385.06,95.27,0.0,491.34,3667.76,3176.42,11537.956,0.66],[\"2017-11-15\",-787.59,13787.59,106.06,0.0,-890.23,3595.02,4485.25,11462.11,-1.04],[\"2017-11-14\",443.92,12556.08,96.59,0.0,397.37,4101.96,3704.59,11582.925,-0.96],[\"2017-11-13\",540.07,12459.93,95.85,0.0,466.03,3995.22,3529.19,11694.996,0.43],[\"2017-11-10\",174.95,12825.05,98.65,0.0,117.84,3532.85,3415.01,11645.047,0.79],[\"2017-11-09\",1413.81,11586.19,89.12,0.0,1305.42,3998.96,2693.54,11553.24,0.92],[\"2017-11-08\",915.08,12084.92,92.96,0.0,841.45,4159.94,3318.49,11447.401,-0.18],[\"2017-11-07\",666.76,12333.24,94.87,0.0,614.32,4062.33,3448.01,11467.969,0.83],[\"2017-11-06\",655.57,12344.43,94.96,0.0,593.05,3899.37,3306.32,11373.736,1.41],[\"2017-11-03\",533.76,12466.24,95.89,0.0,446.81,3282.11,2835.3,11215.194,-0.68],[\"2017-11-02\",779.18,12220.82,94.01,0.0,707.21,2999.0,2291.79,11292.422,-0.51],[\"2017-11-01\",1053.04,11946.96,91.9,0.0,1002.05,3571.01,2568.96,11350.321,-0.15],[\"2017-10-31\",690.81,12309.19,94.69,0.0,632.29,3634.88,3002.59,11367.619,0.49],[\"2017-10-30\",239.83,12760.17,98.16,0.0,173.38,3504.45,3331.07,11312.607,-1.15],[\"2017-10-27\",215.39,12784.61,98.34,0.0,167.06,3057.27,2890.21,11444.524,-0.15],[\"2017-10-26\",241.66,12758.34,98.14,0.0,182.2,3765.41,3583.21,11461.285,0.21],[\"2017-10-25\",328.13,12671.87,97.48,0.0,257.29,2783.81,2526.52,11437.209,0.86],[\"2017-10-24\",-943.46,13943.46,107.26,0.0,-1012.92,2539.9,3552.82,11339.127,0.29],[\"2017-10-23\",-190.19,13190.19,101.46,0.0,-248.59,2544.9,2793.49,11306.307,0.6],[\"2017-10-20\",90.91,12909.09,99.3,0.0,30.77,2764.75,2733.98,11238.877,0.44],[\"2017-10-19\",167.7,12832.3,98.71,0.0,114.12,3032.19,2918.07,11189.553,-0.83],[\"2017-10-18\",223.47,12776.53,98.28,0.0,157.65,2585.82,2428.17,11282.747,0.07],[\"2017-10-17\",1592.31,11407.69,87.75,0.0,1528.46,3794.13,2265.67,11275.341,0.04],[\"2017-10-16\",1208.51,11791.49,90.7,0.0,1099.43,3733.65,2634.22,11271.199,-1.12],[\"2017-10-13\",1084.13,11915.87,91.66,0.0,985.75,2888.8,1903.05,11399.094,0.81],[\"2017-10-12\",893.54,12106.46,93.13,0.0,822.77,2698.49,1875.72,11307.325,-0.05],[\"2017-10-11\",1147.25,11852.75,91.17,0.0,1057.26,4158.56,3101.3,11312.496,-0.15],[\"2017-10-10\",1754.27,11245.73,86.51,0.0,1693.44,3839.09,2145.65,11329.513,0.58],[\"2017-10-09\",2968.41,10031.59,77.17,0.0,2888.99,5159.83,2270.84,11264.273,1.6],[\"2017-09-29\",778.02,12221.98,94.02,0.0,732.21,2482.95,1750.74,11087.187,0.51],[\"2017-09-28\",-138.14,13138.14,101.06,0.0,-180.98,1797.79,1978.77,11031.421,-0.05],[\"2017-09-27\",876.26,12123.74,93.26,0.0,843.99,2425.46,1581.47,11036.78,0.79],[\"2017-09-26\",211.66,12788.34,98.37,0.0,168.5,2348.68,2180.18,10950.769,0.18],[\"2017-09-25\",157.41,12842.59,98.79,0.0,111.87,2579.91,2468.04,10930.67,-1.26],[\"2017-09-22\",1050.18,11949.82,91.92,0.0,969.4,2900.77,1931.37,11069.822,-0.26],[\"2017-09-21\",405.5,12594.5,96.88,0.0,372.22,2831.07,2458.85,11098.339,-0.83],[\"2017-09-20\",1157.62,11842.38,91.1,0.0,1095.32,3076.15,1980.83,11191.13,0.97],[\"2017-09-19\",330.59,12669.41,97.46,0.0,292.05,2833.24,2541.19,11083.899,-0.62],[\"2017-09-18\",1905.98,11094.02,85.34,0.0,1862.39,3602.84,1740.45,11153.532,0.82],[\"2017-09-15\",-99.38,13099.38,100.76,0.0,-303.41,2807.93,3111.34,11063.104,-0.07],[\"2017-09-14\",387.5,12612.5,97.02,0.0,341.51,2316.0,1974.49,11070.492,-0.19],[\"2017-09-13\",634.62,12365.38,95.12,0.0,575.33,2445.49,1870.16,11091.493,0.43],[\"2017-09-11\",309.94,12690.06,97.62,0.0,258.02,2388.46,2130.44,11053.729,0.76],[\"2017-09-08\",822.38,12177.62,93.67,0.0,734.06,2800.19,2066.13,10970.773,0.01],[\"2017-09-07\",809.51,12190.49,93.77,0.0,762.43,2808.82,2046.39,10969.127,-0.5],[\"2017-09-06\",209.43,12790.57,98.39,0.0,130.03,2111.89,1981.86,11024.586,0.34],[\"2017-09-05\",895.93,12104.07,93.11,0.0,831.72,2472.62,1640.9,10986.948,0.22],[\"2017-09-04\",1317.01,11682.99,89.87,0.0,1217.76,3180.59,1962.83,10962.854,0.76],[\"2017-09-01\",2055.2,10944.8,84.19,0.0,2016.81,3712.71,1695.9,10880.557,0.59],[\"2017-08-31\",784.27,12215.73,93.97,0.0,642.37,2768.02,2125.65,10816.644,0.03],[\"2017-08-30\",1136.84,11863.16,91.26,0.0,1052.23,2614.15,1561.92,10813.927,0.48],[\"2017-08-29\",921.23,12078.77,92.91,0.0,871.87,2510.39,1638.52,10762.366,-0.44],[\"2017-08-28\",1959.42,11040.58,84.93,0.0,1921.23,3748.43,1827.2,10809.736,1.41],[\"2017-08-25\",1452.0,11548.0,88.83,0.0,1395.31,3239.05,1843.74,10659.009,1.0],[\"2017-08-24\",590.73,12409.27,95.46,0.0,529.4,2394.38,1864.98,10552.962,-0.63],[\"2017-08-22\",304.58,12695.42,97.66,0.0,264.11,2214.17,1950.06,0.0,0.0],[\"2017-08-21\",435.21,12564.79,96.65,0.0,341.18,2149.21,1808.03,10689.773,0.71],[\"2017-08-18\",-1011.18,14011.18,107.78,0.0,-1060.53,1924.42,2984.95,10614.083,-0.37],[\"2017-08-17\",814.64,12185.36,93.73,0.0,706.97,2291.43,1584.46,10653.73,0.5],[\"2017-08-16\",715.18,12284.82,94.5,0.0,663.75,2381.5,1717.75,10600.779,0.39],[\"2017-08-15\",221.06,12778.94,98.3,0.0,187.27,1911.15,1723.88,10559.778,0.38],[\"2017-08-14\",537.85,12462.15,95.86,0.0,487.5,2198.51,1711.01,10519.804,2.22],[\"2017-08-11\",-91.15,13091.15,100.7,0.0,-126.57,1987.69,2114.26,10291.347,-1.81],[\"2017-08-10\",247.88,12752.12,98.09,0.0,212.11,1989.84,1777.73,10480.641,-0.61],[\"2017-08-09\",570.53,12429.47,95.61,0.0,515.29,1859.29,1344.0,10544.589,0.46],[\"2017-08-08\",864.55,12135.45,93.35,0.0,809.13,2063.98,1254.85,10496.246,0.43],[\"2017-08-07\",1323.62,11676.38,89.82,0.0,1236.35,2440.16,1203.81,10451.083,0.87],[\"2017-08-04\",868.53,12131.47,93.32,0.0,798.0,2221.35,1423.35,10361.231,-0.72],[\"2017-08-03\",1184.02,11815.98,90.89,0.0,1065.1,2534.98,1469.88,10436.172,-0.32],[\"2017-08-01\",635.1,12364.9,95.11,0.0,591.6,1861.07,1269.47,10525.346,0.19],[\"2017-07-31\",1063.16,11936.84,91.82,0.0,1000.68,2226.3,1225.62,10505.044,0.64],[\"2017-07-28\",940.43,12059.57,92.77,0.0,895.6,2238.69,1343.09,10437.938,0.41],[\"2017-07-26\",589.45,12410.55,95.47,0.0,546.98,2386.0,1839.02,10297.343,-0.54],[\"2017-07-25\",1289.14,11710.86,90.08,0.0,1255.91,2534.75,1278.84,10353.211,-0.49],[\"2017-07-21\",1218.5,11781.5,90.63,0.0,1192.78,2174.4,981.62,10364.82,-0.02],[\"2017-07-20\",396.56,12603.44,96.95,0.0,357.94,1848.37,1490.43,10366.983,0.69],[\"2017-07-19\",1107.74,11892.26,91.48,0.0,1049.84,2486.77,1436.93,10295.575,1.9],[\"2017-07-18\",969.04,12030.96,92.55,0.0,917.2,2566.0,1648.8,10103.763,0.48],[\"2017-07-17\",1371.96,11628.04,89.45,0.0,1330.94,2928.17,1597.23,10055.796,-3.57],[\"2017-07-14\",267.33,12732.67,97.94,0.0,196.2,1481.94,1285.74,10427.787,-0.37],[\"2017-07-13\",651.52,12348.48,94.99,0.0,599.63,2001.54,1401.91,10466.103,0.12],[\"2017-07-12\",1079.17,11920.83,91.7,0.0,953.42,2340.87,1387.45,10453.193,-0.14],[\"2017-07-11\",753.74,12246.26,94.2,0.0,702.29,2007.49,1305.2,10467.711,-0.36],[\"2017-07-10\",894.62,12105.38,93.12,0.0,819.65,2105.93,1286.28,10505.601,-0.55],[\"2017-07-07\",481.96,12518.04,96.29,0.0,443.89,1595.59,1151.7,10563.717,0.02],[\"2017-07-06\",-196.51,13196.51,101.51,0.0,-228.07,1564.29,1792.36,10562.055,0.01],[\"2017-07-05\",339.22,12660.78,97.39,0.0,281.07,1517.62,1236.55,10561.089,0.82],[\"2017-07-04\",-201.72,13201.72,101.55,0.0,-239.38,1572.81,1812.19,10474.828,-0.57],[\"2017-07-03\",321.76,12678.24,97.52,0.0,264.57,1474.73,1210.16,10535.046,0.05],[\"2017-06-30\",-112.32,13112.32,100.86,0.0,-150.95,1396.31,1547.26,10529.609,0.17],[\"2017-06-29\",1021.08,11978.92,92.15,0.0,923.7,2362.6,1438.9,10511.86,0.58],[\"2017-06-28\",401.52,12598.48,96.91,0.0,352.53,2677.21,2324.68,10451.565,-0.8],[\"2017-06-27\",750.26,12249.74,94.23,0.0,702.66,2254.52,1551.86,10535.364,-0.02],[\"2017-06-26\",475.64,12524.36,96.34,0.0,441.41,2182.41,1741.0,10537.591,1.65],[\"2017-06-23\",1061.9,11938.1,91.83,0.0,928.0,2502.22,1574.22,10366.777,0.99],[\"2017-06-22\",1279.85,11720.15,90.15,0.0,1242.75,3014.58,1771.83,10265.2,-0.98],[\"2017-06-21\",1050.47,11949.53,91.92,0.0,984.98,2256.29,1271.31,10367.173,0.76],[\"2017-06-20\",494.46,12505.54,96.2,0.0,453.37,1765.51,1312.14,10288.527,0.25],[\"2017-06-19\",1194.85,11805.15,90.81,0.0,1151.21,2338.43,1187.22,10262.8,0.7],[\"2017-06-16\",488.89,12511.11,96.24,0.0,444.57,2407.59,1963.02,10191.24,-0.3],[\"2017-06-15\",869.3,12130.7,93.31,0.0,837.4,2331.77,1494.37,10221.692,0.69],[\"2017-06-14\",-258.04,13258.04,101.98,0.0,-287.79,1608.76,1896.55,10151.534,-0.72],[\"2017-06-13\",697.3,12302.7,94.64,0.0,647.62,2225.87,1578.25,10224.818,1.04],[\"2017-06-12\",97.72,12902.28,99.25,0.0,21.12,2121.16,2100.04,10119.987,-0.56],[\"2017-06-09\",564.23,12435.77,95.66,0.0,503.35,2489.18,1985.83,10177.447,0.28],[\"2017-06-08\",1390.35,11609.65,89.31,0.0,1326.63,2631.47,1304.84,10148.722,0.38],[\"2017-06-07\",1807.93,11192.07,86.09,0.0,1742.92,3208.27,1465.35,10109.876,1.96],[\"2017-06-06\",1232.6,11767.4,90.52,0.0,1186.83,2198.93,1012.1,9915.923,0.74],[\"2017-06-05\",1016.79,11983.21,92.18,0.0,992.85,2043.07,1050.22,9842.602,0.49],[\"2017-06-02\",1026.1,11973.9,92.11,0.0,965.89,2022.76,1056.87,9794.889,0.66],[\"2017-06-01\",266.02,12733.98,97.95,0.0,238.61,1904.18,1665.57,9730.326,-1.36],[\"2017-05-31\",-213.71,13213.71,101.64,0.0,-241.58,1666.11,1907.69,9864.845,0.06]]}'"
      ]
     },
     "execution_count": 27,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ret"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 2",
   "language": "python",
   "name": "python2"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.13"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
